﻿@model IEnumerable<Stardust.Models.PerfilUsuarioBean>

@{
    ViewBag.Title = "Perfiles";
}

@if (!String.IsNullOrEmpty(ViewBag.results)) { 
    <div class="nNote nWarning hideit">
        <p><strong>AVISO: </strong>@ViewBag.results</p>
    </div>
}

<h2>Perfiles</h2>

<p>
    <a href="@Url.Action("Create")"><img src="../../Content/images/icons/color/plus.png", alt="Create" />Añadir perfil</a>
</p>

<table cellpadding = "0" cellspacing = "0" width = "100%" class = "sTable">
    <thead>
        <tr>
            <td>Nombre</td>
            <td>Descripción</td>
            <td></td>
        </tr>
    </thead>

    <tbody>
    @foreach (var item in Model) {
        <tr>
            <td>@Html.DisplayFor(modelItem => item.nombre )</td>
            <td>@Html.DisplayFor(modelItem => item.descripcion )</td>
            <td>
                <a href="@Url.Action("Edit", new { id = item.ID })"><img src="../../Content/images/icons/color/pencil.png", alt="Edit" />Editar </a> | 
                <a href="@Url.Action("Details", new { id = item.ID })"><img src="../../Content/images/icons/color/edit-column.png", alt="Details" />Detalles</a> | 
                <a href="@Url.Action("Delete", new { id = item.ID })"><img src="../../Content/images/icons/color/cross.png", alt="Delete" />Borrar</a>
            </td>
        </tr>
        
    }
    </tbody>
</table>